<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <script src="/html/axios.min.js"></script>
    <script src="/html/util.js"></script>
    <script>
        function land(){
            axios.get("/user/login",{
                params:{
                    userName:$("name").value,
                    pwd:$("pwd").value
                }
            }).then(e =>{
                if (e.data == "ok"){
                    location.href ="/html/index.html"
                }else{
                    $("span").innerText = "登录失败";
                }
            })
        }
    </script>
</head>
<body>
<span id="span" style="color: red"></span>
  用户名:<input type="text" id="name"><br>
  密码:<input type="password" id="pwd"><br>
  <input type="button" value="提交" onclick="land()">



</body>
</html>